home *** CD-ROM | disk | FTP | other *** search
/ Technotools / Technotools (Chestnut CD-ROM)(1993).ISO / misc_pto / autil100 / start.asi < prev    next >
Text File  |  1991-12-13  |  22KB  |  1,086 lines

  1. start:
  2.  
  3. rem This version of START.COM is for the Some ASIC Utilities disk.
  4.  
  5. rem It requires approximately 65K RAM.
  6.  
  7. rem First, initialize the Esc key.
  8.  
  9. b$=chr$(27)
  10.  
  11. rem Next, initialize the Enter(Return) key and space bar.
  12.  
  13. c$=chr$(13)
  14. e$=chr$(32)
  15.  
  16. rem Parameters will go here when they're ready.
  17.  
  18. rem If no parameters, begin from the beginning.
  19.  
  20. cls
  21. print "                                 Matt Roberts"
  22. print "                               3 Cedar St., # 8"
  23. print "                           Montpelier, Vt 05602-3006"
  24. print "                                 (802)223-2553"
  25. print
  26. print
  27. print
  28. print "                           Some ASIC Utilities 1.00"
  29. print
  30. print
  31. print "If you have trouble running the programs on this disk, and the"
  32. print "documentation doesn't seem to help, you can call between 9AM and 9PM"
  33. print "EST, and I'll try to help.  Keep trying."
  34. print
  35. print
  36. print "If you find the files on this disk useful, a donation of $5.00 would"
  37. print "be greatly appreciated.  Thanks."
  38. print
  39. print
  40. print
  41. print
  42. print
  43. print "Press any key to continue. ";
  44. gosub continue:
  45.  
  46. options:
  47. cls
  48. print "Here are your options:"
  49. print
  50. print
  51. print "F1- See a list of the files on this disk."
  52. print
  53. print "F2- Read the text file of your choice, on the screen."
  54. print
  55. print "F3- Print the text file of your choice."
  56. print
  57. print "F4- Shell to DOS."
  58. print
  59. print "F5- Change to 40-column width."
  60. print
  61. print "Esc- Quit and return to DOS."
  62. print
  63. print
  64. print "Please press the key corresponding to your choice. ";
  65.  
  66. wait1:
  67. gosub continue:
  68. if a$=b$ then finish:
  69. if extended=1 then readext:
  70. goto wait1:
  71.  
  72. readext:
  73. if a$=";" then seefiles:
  74. if a$="<" then readfile:
  75. if a$="=" then printdoc:
  76. if a$=">" then shell:
  77. if a$="?" then option40:
  78. goto wait1:
  79.  
  80. rem Here is the routine for listing the files on this disk.
  81.  
  82. seefiles:
  83. cls
  84. print "Here are the files on this disk:"
  85. print
  86. print
  87. print "BEEP.ASI- The ASIC code for BEEP.COM."
  88. print
  89. print "BEEP.COM- Makes your computer go beep."
  90. print
  91. print "BEEP.DOC- The documentation for BEEP.COM."
  92. print
  93. print "BLANKLIN.ASI- The ASIC code for BLANKLIN.COM."
  94. print
  95. print "BLANKLIN.COM- Makes blank lines in DOS 2.X batch files."
  96. print
  97. print "BLANKLIN.DOC- The documentation for BLANKLIN.COM."
  98. print
  99. print "CORRECT.ASI- The ASIC code for CORRECT.COM."
  100. print
  101. print "CORRECT.COM- Batch file utility; rewards correct answers."
  102. print
  103. print "CORRECT.DOC- The documentation for CORRECT.COM."
  104. print
  105. print
  106. print "Press any key to continue. ";
  107. gosub continue:
  108. cls
  109. print "LIST.COM- Excellent utility by Vern Buerg; lists files on the screen."
  110. print
  111. print "LIST.DOC- The documentation for LIST.COM."
  112. print
  113. print "LITTLEBP.ASI- The ASIC code for LITTLEBP.COM."
  114. print
  115. print "LITTLEBP.COM- Makes a short beep on your computer."
  116. print
  117. print "LITTLEBP.DOC- The documentation for LITTLEBP.COM."
  118. print
  119. print "SIREN.ASI- The ASIC code for SIREN.COM."
  120. print
  121. print "SIREN.COM- Makes a siren noise on your computer."
  122. print
  123. print "SIREN.DOC- The documentation for SIREN.COM."
  124. print
  125. print "SMILEDLY.ASI- The ASIC code for SMILEDLY.COM."
  126. print
  127. print "SMILEDLY.COM- Makes a smiley-face, and delays before returning to DOS."
  128. print
  129. print "SMILEDLY.DOC- The documentation for SMILEDLY.COM."
  130. print
  131. print
  132. print "Press any key to continue. ";
  133. gosub continue:
  134. cls
  135. print "SPLAT.ASI- The ASIC code for SPLAT.COM."
  136. print
  137. print "SPLAT.COM- Batch file utility; 'rewards' incorrect answers."
  138. print
  139. print "SPLAT.DOC- The documentation for SPLAT.COM."
  140. print
  141. print "START.ASI- The ASIC code for START.COM."
  142. print
  143. print "START.COM- The file you're using right now."
  144. print
  145. print
  146. print "Press any key to return to the Main Options Menu. ";
  147. gosub continue:
  148. goto options:
  149.  
  150. rem Here is the routine for reading a text file.
  151.  
  152. readfile:
  153. cls
  154. print "To move ahead in the file(s) you are about to view, press PgDn."
  155. print
  156. print "To move back, press PgUp."
  157. print
  158. print "To exit the document, press Esc."
  159. print
  160. print
  161. print "Press any key to see the menu of files. ";
  162. gosub continue:
  163.  
  164. readmenu:
  165. cls
  166. print "Here are the files you can view:"
  167. print
  168. print
  169. print "A- BEEP.ASI              J- SIREN.ASI"
  170. print
  171. print "B- BEEP.DOC              K- SIREN.DOC"
  172. print
  173. print "C- BLANKLIN.ASI          L- SMILEDLY.ASI"
  174. print
  175. print "D- BLANKLIN.DOC          M- SMILEDLY.DOC"
  176. print
  177. print "E- CORRECT.ASI           N- SPLAT.ASI"
  178. print
  179. print "F- CORRECT.DOC           O- SPLAT.DOC"
  180. print
  181. print "G- LIST.DOC              P- START.ASI"
  182. print
  183. print "H- LITTLEBP.ASI"
  184. print
  185. print "I- LITTLEBP.DOC          Esc- Return to the Main Options Menu."
  186. print
  187. print
  188. print "Please press the key corresponding to your choice. ";
  189. gosub continue:
  190.  
  191. if a$=b$ then options:
  192. print a$;
  193. if a$="a" then readbeea:
  194. if a$="A" then readbeea:
  195. if a$="b" then readbeed:
  196. if a$="B" then readbeed:
  197. if a$="c" then readblaa:
  198. if a$="C" then readblaa:
  199. if a$="d" then readblad:
  200. if a$="D" then readblad:
  201. if a$="e" then readcora:
  202. if a$="E" then readcora:
  203. if a$="f" then readcord:
  204. if a$="F" then readcord:
  205. if a$="g" then readlist:
  206. if a$="G" then readlist:
  207. if a$="h" then readlita:
  208. if a$="H" then readlita:
  209. if a$="i" then readlitd:
  210. if a$="I" then readlitd:
  211. if a$="j" then readsira:
  212. if a$="J" then readsira:
  213. if a$="k" then readsird:
  214. if a$="K" then readsird:
  215. if a$="l" then readsmia:
  216. if a$="L" then readsmia:
  217. if a$="m" then readsmid:
  218. if a$="M" then readsmid:
  219. if a$="n" then readspla:
  220. if a$="N" then readspla:
  221. if a$="o" then readspld:
  222. if a$="O" then readspld:
  223. if a$="p" then readstar:
  224. if a$="P" then readstar:
  225. goto readmenu:
  226.  
  227. readbeea:
  228. call ("list.com"," beep.asi")
  229. goto readmenu:
  230. readbeed:
  231. call ("list.com"," beep.doc")
  232. goto readmenu:
  233. readblaa:
  234. call ("list.com"," blanklin.asi")
  235. goto readmenu:
  236. readblad:
  237. call ("list.com"," blanklin.doc")
  238. goto readmenu:
  239. readcora:
  240. call ("list.com"," correct.asi")
  241. goto readmenu:
  242. readcord:
  243. call ("list.com"," correct.doc")
  244. goto readmenu:
  245. readlist:
  246. call ("list.com"," list.doc")
  247. goto readmenu:
  248. readlita:
  249. call ("list.com"," littlebp.asi")
  250. goto readmenu:
  251. readlitd:
  252. call ("list.com"," littlebp.doc")
  253. goto readmenu:
  254. readsira:
  255. call ("list.com"," siren.asi")
  256. goto readmenu:
  257. readsird:
  258. call ("list.com"," siren.doc")
  259. goto readmenu:
  260. readsmia:
  261. call ("list.com"," smiledly.asi")
  262. goto readmenu:
  263. readsmid:
  264. call ("list.com"," smiledly.doc")
  265. goto readmenu:
  266. readspla:
  267. call ("list.com"," splat.asi")
  268. goto readmenu:
  269. readspld:
  270. call ("list.com"," splat.doc")
  271. goto readmenu:
  272. readstar:
  273. call ("list.com"," start.asi")
  274. goto readmenu:
  275.  
  276.  
  277. rem Here is the routine for printing a file.
  278.  
  279. printdoc:
  280. cls
  281. print "Please ready your printer; press any key to see the menu of files. ";
  282. gosub continue:
  283.  
  284. printmen:
  285. cls
  286. print "Here are the files you can print:"
  287. print
  288. print
  289. print "A- BEEP.ASI              J- SIREN.ASI"
  290. print
  291. print "B- BEEP.DOC              K- SIREN.DOC"
  292. print
  293. print "C- BLANKLIN.ASI          L- SMILEDLY.ASI"
  294. print
  295. print "D- BLANKLIN.DOC          M- SMILEDLY.DOC"
  296. print
  297. print "E- CORRECT.ASI           N- SPLAT.ASI"
  298. print
  299. print "F- CORRECT.DOC           O- SPLAT.DOC"
  300. print
  301. print "G- LIST.DOC              P- START.ASI"
  302. print
  303. print "H- LITTLEBP.ASI"
  304. print
  305. print "I- LITTLEBP.DOC          Esc- Return to the Main Options Menu."
  306. print
  307. print
  308. print "Please press the key corresponding to your choice. ";
  309. gosub continue:
  310.  
  311. wait2:
  312. if a$=b$ then options:
  313. if a$="a" then printbea:
  314. if a$="A" then printbea:
  315. if a$="b" then printbed:
  316. if a$="B" then printbed:
  317. if a$="c" then printbla:
  318. if a$="C" then printbla:
  319. if a$="d" then printbld:
  320. if a$="D" then printbld:
  321. if a$="e" then printcoa:
  322. if a$="E" then printcoa:
  323. if a$="f" then printcod:
  324. if a$="F" then printcod:
  325. if a$="g" then printlis:
  326. if a$="G" then printlis:
  327. if a$="h" then printlia:
  328. if a$="H" then printlia:
  329. if a$="i" then printlid:
  330. if a$="I" then printlid:
  331. if a$="j" then printsia:
  332. if a$="J" then printsia:
  333. if a$="k" then printsid:
  334. if a$="K" then printsid:
  335. if a$="l" then printsma:
  336. if a$="L" then printsma:
  337. if a$="m" then printsmd:
  338. if a$="M" then printsmd:
  339. if a$="n" then printspa:
  340. if a$="N" then printspa:
  341. if a$="o" then printspd:
  342. if a$="O" then printspd:
  343. if a$="p" then printsta:
  344. if a$="P" then printsta:
  345. goto wait2:
  346.  
  347. printbea:
  348. file$="beep.asi"
  349. gosub printfil:
  350. goto printmen:
  351.  
  352. printbed:
  353. file$="beep.doc"
  354. gosub printfil:
  355. goto printmen:
  356.  
  357. printbla:
  358. file$="blanklin.asi"
  359. gosub printfil:
  360. goto printmen:
  361.  
  362. printbld:
  363. file$="blanklin.doc"
  364. gosub printfil:
  365. goto printmen:
  366.  
  367. printcoa:
  368. file$="correct.asi"
  369. gosub printfil:
  370. goto printmen:
  371.  
  372. printcod:
  373. file$="correct.doc"
  374. gosub printfil:
  375. goto printmen:
  376.  
  377. printlis:
  378. file$="list.doc"
  379. gosub printfil:
  380. goto printmen:
  381.  
  382. printlia:
  383. file$="littlebp.asi"
  384. gosub printfil:
  385. goto printmen:
  386.  
  387. printlid:
  388. file$="littlebp.doc"
  389. gosub printfil:
  390. goto printmen:
  391.  
  392. printsia:
  393. file$="siren.asi"
  394. gosub printfil:
  395. goto printmen:
  396.  
  397. printsid:
  398. file$="siren.doc"
  399. gosub printfil:
  400. goto printmen:
  401.  
  402. printsma:
  403. file$="smiledly.asi"
  404. gosub printfil:
  405. goto printmen:
  406.  
  407. printsmd:
  408. file$="smiledly.doc"
  409. gosub printfil:
  410. goto printmen:
  411.  
  412. printspa:
  413. file$="splat.asi"
  414. gosub printfil:
  415. goto printmen:
  416.  
  417. printspd:
  418. file$="splat.doc"
  419. gosub printfil:
  420. goto printmen:
  421.  
  422. printsta:
  423. file$="start.asi"
  424. gosub printfil:
  425. goto printmen:
  426.  
  427.  
  428. rem Here is the file-printing subroutine.
  429.  
  430. printfil:
  431. cls
  432. f$=chr$(12)
  433. open "i",1,file$
  434.  
  435. if error=2 then
  436. print ""
  437. print ""
  438. print "File not found."
  439. print
  440. print
  441. print "Press any key to continue. ";
  442. gosub continue:
  443. close 1
  444. return
  445. endif
  446.  
  447. heading:
  448. cls
  449. print "Printing...";
  450. realfile$=ucase$(file$)
  451. color 0,7
  452. print realfile$
  453. color 7,0
  454. print
  455. print
  456. print "Press space bar to pause printing, or Esc to quit."
  457. print
  458. print
  459.  
  460. printmor:
  461. input# 1, line$ crlf
  462.  
  463. if error=96 then
  464. lprint line$
  465. goto blanklin:
  466. endif
  467.  
  468. contlprn:
  469. lprint line$
  470.  
  471. a$=inkey$
  472.  
  473. if a$=b$ then
  474. print "Printing has been terminated.  The printer may still have data in its"
  475. print "buffer.  If so, it will continue printing until the buffer is empty."
  476. print
  477. lprint f$
  478. close 1
  479. file$=""
  480. print "Press any key to continue. ";
  481. gosub continue:
  482. return
  483. endif
  484.  
  485. if a$=e$ then pause: else nopause:
  486.  
  487. pause:
  488.  
  489. print "Press any key to resume printing. ";
  490.  
  491. pausemor:
  492. a$=inkey$
  493. if a$="" then pausemor:
  494. a$=""
  495. goto heading:
  496.  
  497. nopause:
  498. if error=99 then eofp:
  499. goto printmor:
  500.  
  501. blanklin:
  502. input# 1, line$ crlf
  503. if line$="" then printmor: else contlprn:
  504.  
  505. eofp:
  506. lprint line$
  507. print "Finished."
  508. print
  509. close 1
  510. lprint f$
  511. print "Press any key to continue. ";
  512. gosub continue:
  513. return
  514.  
  515.  
  516. rem This is the end of the routine for printing text files.
  517.  
  518.  
  519. rem Here is the routine for shelling to DOS.
  520.  
  521. shell:
  522. cls
  523. print "On which drive is your COMMAND.COM (don't type the colon)? ";
  524. gosub continue:
  525. path$=a$+":\command.com"
  526. cls
  527. print "Use the DOS command EXIT to return to START.COM."
  528. print
  529. call path$,""
  530. goto options:
  531.  
  532.  
  533. rem Here is the routine for START.COM in 40-column mode.
  534.  
  535. option40:
  536. width 40
  537. print "Here are your options:"
  538. print
  539. print
  540. print "F1- See a list of disk files."
  541. print
  542. print "F2- Read the text file of your choice,"
  543. print "on the screen."
  544. print
  545. print "F3- Print a text file."
  546. print
  547. print "F4- Shell to DOS."
  548. print
  549. print "F5- Return to 80-column mode."
  550. print
  551. print "Esc- Quit and return to DOS."
  552. print
  553. print
  554. print "Please press the key corresponding to"
  555. print "your choice. ";
  556.  
  557. wait3:
  558. gosub continue:
  559. if a$=b$ then finish:
  560. if extended=1 then readex40:
  561. goto wait3:
  562.  
  563. readex40:
  564. if a$=";" then seefil40:
  565. if a$="<" then rdfile40:
  566. if a$="=" then prtdoc40:
  567. if a$=">" then shell40:
  568. if a$="?" then width80:
  569. goto wait3:
  570.  
  571.  
  572. rem Here is the routine for viewing disk files in 40-column mode.
  573.  
  574. seefil40:
  575. width 40
  576. print "Here are the files on this disk:"
  577. print
  578. print
  579. print "BEEP.ASI- The ASIC code for BEEP.COM."
  580. print
  581. print "BEEP.COM- Makes your computer go beep."
  582. print
  583. print "BEEP.DOC- The documentation for"
  584. print "BEEP.COM."
  585. print
  586. print "BLANKLIN.ASI- The ASIC code for"
  587. print "BLANKLIN.COM."
  588. print
  589. print "BLANKLIN.COM- Makes blank lines in DOS"
  590. print "2.X batch files."
  591. print
  592. print "BLANKLIN.DOC- The documentation for"
  593. print "BLANKLIN.COM."
  594. print
  595. print "CORRECT.ASI- The ASIC code for"
  596. print "CORRECT.COM."
  597. print
  598. print
  599. print "Press any key to continue. ";
  600. gosub continue:
  601. cls
  602. print "CORRECT.COM- Batch file utility to re-"
  603. print "ward correct answers."
  604. print
  605. print "CORRECT.DOC- The documentation for"
  606. print "CORRECT.COM."
  607. print
  608. print "LIST.COM- Excellent utility by Vern"
  609. print "Buerg; prints files on the screen."
  610. print
  611. print "LIST.DOC- The documentation for"
  612. print "LIST.COM."
  613. print
  614. print "LITTLEBP.ASI- The ASIC code for"
  615. print "LITTLEBP.COM."
  616. print
  617. print "LITTLEBP.COM- Makes a short beep on"
  618. print "your computer."
  619. print
  620. print "LITTLEBP.DOC- The documentation for"
  621. print "LITTLEBP.COM."
  622. print
  623. print
  624. print "Press any key to continue. ";
  625. gosub continue:
  626. cls
  627. print "SIREN.ASI- The ASIC code for"
  628. print "SIREN.COM."
  629. print
  630. print "SIREN.COM- Makes a siren noise."
  631. print
  632. print "SIREN.DOC- The documentation for"
  633. print "SIREN.COM."
  634. print
  635. print "SMILEDLY.ASI- The ASIC code for"
  636. print "SMILEDLY.COM."
  637. print
  638. print "SMILEDLY.COM- Makes a smiley-face, and"
  639. print "delays before returning to DOS."
  640. print
  641. print "SMILEDLY.DOC- The documentation for"
  642. print "SMILEDLY.COM."
  643. print
  644. print "SPLAT.ASI- The ASIC code for"
  645. print "SPLAT.COM."
  646. print
  647. print
  648. print "Press any key to continue. ";
  649. gosub continue:
  650. cls
  651. print "SPLAT.COM- Batch file utility; rewards"
  652. print "incorrect answers."
  653. print
  654. print "START.ASI- The ASIC code for"
  655. print "START.COM."
  656. print
  657. print "START.COM- The file you're using right"
  658. print "now."
  659. print
  660. print
  661. print "Press any key to return to the Main"
  662. print "Options Menu. ";
  663. gosub continue:
  664. goto option40:
  665.  
  666.  
  667. rem Here is the routine for reading a text file in 40-column mode.
  668.  
  669. rdfile40:
  670. width 40
  671. print "To move ahead in the file(s) you are"
  672. print "about to view, press PgDn."
  673. print
  674. print "To move back, press PgUp."
  675. print
  676. print "To move to the side, use the arrow"
  677. print "keys."
  678. print
  679. print "To exit the document, press Esc."
  680. print
  681. print
  682. print "Press any key to see the menu of"
  683. print "files. ";
  684. gosub continue:
  685.  
  686. rdmenu40:
  687. cls
  688. print "Here are the files you can view:"
  689. print
  690. print
  691. print "A- BEEP.ASI           J- SIREN.ASI"
  692. print
  693. print "B- BEEP.DOC           K- SIREN.DOC"
  694. print
  695. print "C- BLANKLIN.ASI       L- SMILEDLY.ASI"
  696. print
  697. print "D- BLANKLIN.DOC       M- SMILEDLY.DOC"
  698. print
  699. print "E- CORRECT.ASI        N- SPLAT.ASI"
  700. print
  701. print "F- CORRECT.DOC        O- SPLAT.DOC"
  702. print
  703. print "G- LIST.DOC           P- START.ASI"
  704. print
  705. print "H- LITTLEBP.ASI"
  706. print
  707. print "I- LITTLEBP.DOC       Esc- Main Menu."
  708. print
  709. print
  710. print "Please press the key corresponding to"
  711. print "your choice. ";
  712. gosub continue:
  713.  
  714. if a$=b$ then option40:
  715. print a$;
  716. if a$="a" then rdbeea40:
  717. if a$="A" then rdbeea40:
  718. if a$="b" then rdbeed40:
  719. if a$="B" then rdbeed40:
  720. if a$="c" then rdblaa40:
  721. if a$="C" then rdblaa40:
  722. if a$="d" then rdblad40:
  723. if a$="D" then rdblad40:
  724. if a$="e" then rdcora40:
  725. if a$="E" then rdcora40:
  726. if a$="f" then rdcord40:
  727. if a$="F" then rdcord40:
  728. if a$="g" then rdlist40:
  729. if a$="G" then rdlist40:
  730. if a$="h" then rdlita40:
  731. if a$="H" then rdlita40:
  732. if a$="i" then rdlitd40:
  733. if a$="I" then rdlitd40:
  734. if a$="j" then rdsira40:
  735. if a$="J" then rdsira40:
  736. if a$="k" then rdsird40:
  737. if a$="K" then rdsird40:
  738. if a$="l" then rdsmia40:
  739. if a$="L" then rdsmia40:
  740. if a$="m" then rdsmid40:
  741. if a$="M" then rdsmid40:
  742. if a$="n" then rdspla40:
  743. if a$="N" then rdspla40:
  744. if a$="o" then rdspld40:
  745. if a$="O" then rdspld40:
  746. if a$="p" then rdstar40:
  747. if a$="P" then rdstar40:
  748. goto rdmenu40:
  749.  
  750. rdbeea40:
  751. call ("list.com"," beep.asi")
  752. goto rdmenu40:
  753. rdbeed40:
  754. call ("list.com"," beep.doc")
  755. goto rdmenu40:
  756. rdblaa40:
  757. call ("list.com"," blanklin.asi")
  758. goto rdmenu40:
  759. rdblad40:
  760. call ("list.com"," blanklin.doc")
  761. goto rdmenu40:
  762. rdcora40:
  763. call ("list.com"," correct.asi")
  764. goto rdmenu40:
  765. rdcord40:
  766. call ("list.com"," correct.doc")
  767. goto rdmenu40:
  768. rdlist40:
  769. call ("list.com"," list.doc")
  770. goto rdmenu40:
  771. rdlita40:
  772. call ("list.com"," littlebp.asi")
  773. goto rdmenu40:
  774. rdlitd40:
  775. call ("list.com"," littlebp.doc")
  776. goto rdmenu40:
  777. rdsira40:
  778. call ("list.com"," siren.asi")
  779. goto rdmenu40:
  780. rdsird40:
  781. call ("list.com"," siren.doc")
  782. goto rdmenu40:
  783. rdsmia40:
  784. call ("list.com"," smiledly.asi")
  785. goto rdmenu40:
  786. rdsmid40:
  787. call ("list.com"," smiledly.doc")
  788. goto rdmenu40:
  789. rdspla40:
  790. call ("list.com"," splat.asi")
  791. goto rdmenu40:
  792. rdspld40:
  793. call ("list.com"," splat.doc")
  794. goto rdmenu40:
  795. rdstar40:
  796. call ("list.com"," start.asi")
  797. goto rdmenu40:
  798.  
  799.  
  800. rem Here is the routine for printing text files.
  801.  
  802. prtdoc40:
  803. width 40
  804. print "Please ready your printer; press any"
  805. print "key to see the menu of files."
  806. gosub continue:
  807.  
  808. prmenu40:
  809. cls
  810. print "Here are the files you can print:"
  811. print
  812. print
  813. print "A- BEEP.ASI           J- SIREN.ASI"
  814. print
  815. print "B- BEEP.DOC           K- SIREN.DOC"
  816. print
  817. print "C- BLANKLIN.ASI       L- SMILEDLY.ASI"
  818. print
  819. print "D- BLANKLIN.DOC       M- SMILEDLY.DOC"
  820. print
  821. print "E- CORRECT.ASI        N- SPLAT.ASI"
  822. print
  823. print "F- CORRECT.DOC        O- SPLAT.DOC"
  824. print
  825. print "G- LIST.DOC           P- START.ASI"
  826. print
  827. print "H- LITTLEBP.ASI"
  828. print
  829. print "I- LITTLEBP.DOC       Esc- Main Menu."
  830. print
  831. print
  832. print "Please press the key corresponding to"
  833. print "your choice. ";
  834.  
  835. wait4:
  836. gosub continue:
  837. if a$=b$ then option40:
  838. if a$="a" then prbeea40:
  839. if a$="A" then prbeea40:
  840. if a$="b" then prbeed40:
  841. if a$="B" then prbeed40:
  842. if a$="c" then prblaa40:
  843. if a$="C" then prblaa40:
  844. if a$="d" then prblad40:
  845. if a$="D" then prblad40:
  846. if a$="e" then prcora40:
  847. if a$="E" then prcora40:
  848. if a$="f" then prcord40:
  849. if a$="F" then prcord40:
  850. if a$="g" then prlist40:
  851. if a$="G" then prlist40:
  852. if a$="h" then prlita40:
  853. if a$="H" then prlita40:
  854. if a$="i" then prlitd40:
  855. if a$="I" then prlitd40:
  856. if a$="j" then prsira40:
  857. if a$="J" then prsira40:
  858. if a$="k" then prsird40:
  859. if a$="K" then prsird40:
  860. if a$="l" then prsmia40:
  861. if a$="L" then prsmia40:
  862. if a$="m" then prsmid40:
  863. if a$="M" then prsmid40:
  864. if a$="n" then prspla40:
  865. if a$="N" then prspla40:
  866. if a$="o" then prspld40:
  867. if a$="O" then prspld40:
  868. if a$="p" then prstar40:
  869. if a$="P" then prstar40:
  870. goto wait4:
  871.  
  872. prbeea40:
  873. file$="beep.asi"
  874. gosub prfile40:
  875. goto prmenu40:
  876.  
  877. prbeed40:
  878. file$="beep.doc"
  879. gosub prfile40:
  880. goto prmenu40:
  881.  
  882. prblaa40:
  883. file$="blanklin.asi"
  884. gosub prfile40:
  885. goto prmenu40:
  886.  
  887. prblad40:
  888. file$="blanklin.doc"
  889. gosub prfile40:
  890. goto prmenu40:
  891.  
  892. prcora40:
  893. file$="correct.asi"
  894. gosub prfile40:
  895. goto prmenu40:
  896.  
  897. prcord40:
  898. file$="correct.doc"
  899. gosub prfile40:
  900. goto prmenu40:
  901.  
  902. prlist40:
  903. file$="list.doc"
  904. gosub prfile40:
  905. goto prmenu40:
  906.  
  907. prlita40:
  908. file$="littlebp.asi"
  909. gosub prfile40:
  910. goto prmenu40:
  911.  
  912. prlitd40:
  913. file$="littlebp.doc"
  914. gosub prfile40:
  915. goto prmenu40:
  916.  
  917. prsira40:
  918. file$="siren.asi"
  919. gosub prfile40:
  920. goto prmenu40:
  921.  
  922. prsird40:
  923. file$="siren.doc"
  924. gosub prfile40:
  925. goto prmenu40:
  926.  
  927. prsmia40:
  928. file$="smiledly.asi"
  929. gosub prfile40:
  930. goto prmenu40:
  931.  
  932. prsmid40:
  933. file$="smiledly.doc"
  934. gosub prfile40:
  935. goto prmenu40:
  936.  
  937. prspla40:
  938. file$="splat.asi"
  939. gosub prfile40:
  940. goto prmenu40:
  941.  
  942. prspld40:
  943. file$="splat.doc"
  944. gosub prfile40:
  945. goto prmenu40:
  946.  
  947. prstar40:
  948. file$="start.asi"
  949. gosub prfile40:
  950. goto prmenu40:
  951.  
  952.  
  953. rem Here is the routine for printing a file in 40-column mode.
  954.  
  955. prfile40:
  956. cls
  957. f$=chr$(12)
  958. open "i",1,file$
  959.  
  960. if error=2 then
  961. print ""
  962. print ""
  963. print "File not found."
  964. print
  965. print
  966. print "Press any key to continue. ";
  967. gosub continue:
  968. close 1
  969. return
  970. endif
  971.  
  972. headng40:
  973. cls
  974. print "Printing...";
  975. realfile$=ucase$(file$)
  976. color 0,7
  977. print realfile$
  978. color 7,0
  979. print
  980. print
  981. print "Press space bar to pause printing, or"
  982. print "Esc to quit."
  983. print
  984. print
  985.  
  986. prntmr40:
  987. input# 1, line$ crlf
  988.  
  989. if error=96 then
  990. lprint line$
  991. goto blnkln40:
  992. endif
  993.  
  994. contpr40:
  995. lprint line$
  996.  
  997. a$=inkey$
  998.  
  999. if a$=b$ then
  1000. print "Printing has been terminated.  The"
  1001. print "printer may still have data in its"
  1002. print "buffer.  If so, it will continue"
  1003. print "printing until the buffer is empty."
  1004. print
  1005. lprint f$
  1006. close 1
  1007. file$=""
  1008. print "Press any key to continue. ";
  1009. gosub continue:
  1010. return
  1011. endif
  1012.  
  1013. if a$=e$ then pause40: else nopaus40:
  1014.  
  1015. pause40:
  1016.  
  1017. print "Press any key to resume printing. ";
  1018.  
  1019. pausmr40:
  1020. a$=inkey$
  1021. if a$="" then pausmr40:
  1022. a$=""
  1023. goto headng40:
  1024.  
  1025. nopaus40:
  1026. if error=99 then eofp40:
  1027. goto prntmr40:
  1028.  
  1029. blnkln40:
  1030. input# 1, line$ crlf
  1031. if line$="" then prntmr40: else contpr40:
  1032.  
  1033. eofp40:
  1034. lprint line$
  1035. print "Finished."
  1036. print
  1037. close 1
  1038. lprint f$
  1039. print "Press any key to continue. ";
  1040. gosub continue:
  1041. return
  1042.  
  1043. rem This is the end of the routine for printing a file in 40-column mode.
  1044.  
  1045.  
  1046. rem Here is the routine for shelling to DOS in 40-column mode.
  1047.  
  1048. shell40:
  1049. width 40
  1050. print "On which drive is your COMMAND.COM?"
  1051. print "Don't type the colon. ";
  1052. gosub continue:
  1053. path$=a$+":\command.com"
  1054. cls
  1055. print "Use the DOS command EXIT to return to"
  1056. print "START.COM."
  1057. print
  1058. call path$,""
  1059. goto option40:
  1060.  
  1061. rem This is the end of the routine for shelling to DOS in 40-column mode.
  1062.  
  1063.  
  1064. rem Here is the routine for returning to 80-column width.
  1065.  
  1066. width80:
  1067. width 80
  1068. goto options:
  1069.  
  1070. rem This is the end of the routine for returning to 80-column mode.
  1071.  
  1072.  
  1073. rem Here is the routine for continuing when the user presses a key.
  1074.  
  1075. continue:
  1076. wait:
  1077. a$=inkey$
  1078. if a$="" then wait:
  1079. return
  1080.  
  1081. rem Here is the routine for ending the program and returning to DOS.
  1082.  
  1083. finish:
  1084. cls
  1085. end
  1086.